import request from "@/utils/request";

// 查询规则执行动作列表
export function selectIotRulesActionList(query) {
  return request({
    url: "/iot/action/list",
    method: "get",
    params: query,
  });
}

// 获取规则执行动作详细信息
export function selectIotRulesActionByActionId(actionId) {
  return request({
    url: "/iot/action/" + actionId,
    method: "get",
  });
}

// 新增规则执行动作
export function addIotRulesAction(data) {
  return request({
    url: "/iot/action",
    method: "post",
    data: data,
  });
}

// 修改规则执行动作
export function updateIotRulesAction(data) {
  return request({
    url: "/iot/action",
    method: "put",
    data: data,
  });
}

// 删除规则执行动作
export function deleteIotRulesActionByActionIds(actionIds) {
  return request({
    url: "/iot/action/" + actionIds,
    method: "delete",
  });
}
